Integrand size = 13, antiderivative size = 43 \[ \int \cos (a+b x) \cos (c+d x) \, dx=\frac {\sin (a-c+(b-d) x)}{2 (b-d)}+\frac {\sin (a+c+(b+d) x)}{2 (b+d)} \]
[Out]
Time = 0.04 (sec) , antiderivative size = 43, normalized size of antiderivative = 1.00, number of steps used = 4, number of rules used = 2, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.154, Rules used = {4666, 2717} \[ \int \cos (a+b x) \cos (c+d x) \, dx=\frac {\sin (a+x (b-d)-c)}{2 (b-d)}+\frac {\sin (a+x (b+d)+c)}{2 (b+d)} \]
[In]
[Out]
Rule 2717
Rule 4666
Rubi steps \begin{align*} \text {integral}& = \int \left (\frac {1}{2} \cos (a-c+(b-d) x)+\frac {1}{2} \cos (a+c+(b+d) x)\right ) \, dx \\ & = \frac {1}{2} \int \cos (a-c+(b-d) x) \, dx+\frac {1}{2} \int \cos (a+c+(b+d) x) \, dx \\ & = \frac {\sin (a-c+(b-d) x)}{2 (b-d)}+\frac {\sin (a+c+(b+d) x)}{2 (b+d)} \\ \end{align*}
Time = 0.20 (sec) , antiderivative size = 43, normalized size of antiderivative = 1.00 \[ \int \cos (a+b x) \cos (c+d x) \, dx=\frac {\sin (a-c+(b-d) x)}{2 (b-d)}+\frac {\sin (a+c+(b+d) x)}{2 (b+d)} \]
[In]
[Out]
Time = 0.30 (sec) , antiderivative size = 40, normalized size of antiderivative = 0.93
method | result | size |
default | \(\frac {\sin \left (a -c +\left (b -d \right ) x \right )}{2 b -2 d}+\frac {\sin \left (a +c +\left (b +d \right ) x \right )}{2 b +2 d}\) | \(40\) |
parallelrisch | \(\frac {\left (b +d \right ) \sin \left (a -c +\left (b -d \right ) x \right )+\sin \left (a +c +\left (b +d \right ) x \right ) \left (b -d \right )}{2 b^{2}-2 d^{2}}\) | \(48\) |
risch | \(\frac {\sin \left (x b -d x +a -c \right ) b}{2 \left (b -d \right ) \left (b +d \right )}+\frac {\sin \left (x b -d x +a -c \right ) d}{2 \left (b -d \right ) \left (b +d \right )}+\frac {\sin \left (x b +d x +a +c \right ) b}{2 \left (b -d \right ) \left (b +d \right )}-\frac {\sin \left (x b +d x +a +c \right ) d}{2 \left (b -d \right ) \left (b +d \right )}\) | \(108\) |
norman | \(\frac {\frac {2 b \tan \left (\frac {a}{2}+\frac {x b}{2}\right )}{b^{2}-d^{2}}-\frac {2 d \tan \left (\frac {d x}{2}+\frac {c}{2}\right )}{b^{2}-d^{2}}-\frac {2 b \tan \left (\frac {a}{2}+\frac {x b}{2}\right ) \tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}}{b^{2}-d^{2}}+\frac {2 d \tan \left (\frac {a}{2}+\frac {x b}{2}\right )^{2} \tan \left (\frac {d x}{2}+\frac {c}{2}\right )}{b^{2}-d^{2}}}{\left (1+\tan \left (\frac {a}{2}+\frac {x b}{2}\right )^{2}\right ) \left (1+\tan \left (\frac {d x}{2}+\frac {c}{2}\right )^{2}\right )}\) | \(147\) |
[In]
[Out]
none
Time = 0.24 (sec) , antiderivative size = 42, normalized size of antiderivative = 0.98 \[ \int \cos (a+b x) \cos (c+d x) \, dx=\frac {b \cos \left (d x + c\right ) \sin \left (b x + a\right ) - d \cos \left (b x + a\right ) \sin \left (d x + c\right )}{b^{2} - d^{2}} \]
[In]
[Out]
Leaf count of result is larger than twice the leaf count of optimal. 153 vs. \(2 (32) = 64\).
Time = 0.32 (sec) , antiderivative size = 153, normalized size of antiderivative = 3.56 \[ \int \cos (a+b x) \cos (c+d x) \, dx=\begin {cases} x \cos {\left (a \right )} \cos {\left (c \right )} & \text {for}\: b = 0 \wedge d = 0 \\- \frac {x \sin {\left (a - d x \right )} \sin {\left (c + d x \right )}}{2} + \frac {x \cos {\left (a - d x \right )} \cos {\left (c + d x \right )}}{2} - \frac {\sin {\left (a - d x \right )} \cos {\left (c + d x \right )}}{2 d} & \text {for}\: b = - d \\\frac {x \sin {\left (a + d x \right )} \sin {\left (c + d x \right )}}{2} + \frac {x \cos {\left (a + d x \right )} \cos {\left (c + d x \right )}}{2} + \frac {\sin {\left (a + d x \right )} \cos {\left (c + d x \right )}}{2 d} & \text {for}\: b = d \\\frac {b \sin {\left (a + b x \right )} \cos {\left (c + d x \right )}}{b^{2} - d^{2}} - \frac {d \sin {\left (c + d x \right )} \cos {\left (a + b x \right )}}{b^{2} - d^{2}} & \text {otherwise} \end {cases} \]
[In]
[Out]
none
Time = 0.25 (sec) , antiderivative size = 40, normalized size of antiderivative = 0.93 \[ \int \cos (a+b x) \cos (c+d x) \, dx=\frac {\sin \left (b x + d x + a + c\right )}{2 \, {\left (b + d\right )}} - \frac {\sin \left (-b x + d x - a + c\right )}{2 \, {\left (b - d\right )}} \]
[In]
[Out]
none
Time = 0.29 (sec) , antiderivative size = 40, normalized size of antiderivative = 0.93 \[ \int \cos (a+b x) \cos (c+d x) \, dx=\frac {\sin \left (b x + d x + a + c\right )}{2 \, {\left (b + d\right )}} + \frac {\sin \left (b x - d x + a - c\right )}{2 \, {\left (b - d\right )}} \]
[In]
[Out]
Time = 22.30 (sec) , antiderivative size = 84, normalized size of antiderivative = 1.95 \[ \int \cos (a+b x) \cos (c+d x) \, dx=\frac {b\,\left (\frac {\sin \left (a+c+b\,x+d\,x\right )}{2}+\frac {\sin \left (a-c+b\,x-d\,x\right )}{2}\right )}{b^2-d^2}-\frac {d\,\left (\frac {\sin \left (a+c+b\,x+d\,x\right )}{2}-\frac {\sin \left (a-c+b\,x-d\,x\right )}{2}\right )}{b^2-d^2} \]
[In]
[Out]